# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.db import models
from datetime import datetime
# Create your models here.


class TimeSlotNetFlow(models.Model):
    firewall_tx = models.CharField("防火墙出口流量", max_length=16)
    firewall_rx = models.CharField("防火墙进口流量", max_length=16)
    switch_tx = models.CharField("交换机出口流量", max_length=16)
    switch_rx = models.CharField("交换机进口流量", max_length=16)
    start_time = models.DateTimeField("开始时间", default=datetime.now)
    end_time = models.DateTimeField("結束时间", default=datetime.now)


class TotalNetFlow(models.Model):
    firewall_tx_total = models.CharField("防火墙出口总流量", default="0", max_length=16)
    firewall_rx_total = models.CharField("防火墙进口总流量", default="0", max_length=16)
    switch_tx_total = models.CharField("交换机出口总流量", default="0", max_length=16)
    switch_rx_total = models.CharField("交换机进口总流量", default="0", max_length=16)
    recoder = models.CharField("记录原因", max_length=128, default="每天记录一次")
    add_time = models.DateTimeField("记录时间", default=datetime.now)
